/*
 * @Date: 2023-04-12 16:09:27
 * @LastEditors: jacky02
 * @LastEditTime: 2023-04-27 21:00:10
 */
const path = require("path");
module.exports = {
  // webpack 配置
  webpack: {
    // 配置别名
    alias: {
      // 约定：使用 @ 表示 src 文件所在路径
      "@": path.resolve(__dirname, "src"),
      img: '@/img',
      pages: '@/Pages',
    },
    configure:(webpackConfig,{env,paths}) => {
        // 修改build的生成文件名称
        paths.appBuild = 'dist';
        webpackConfig.output ={
          ...webpackConfig.output,
          path:path.resolve(__dirname,'dist'),
        //   build改./
        //   publicPath:'./'
          publicPath:'/'
        }
        return webpackConfig;
      },
  },
};
